package com.dao;

import com.pojo.PurchaseOrder;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

@Repository
public interface PurchaseMapper {
    @Insert("insert into purchase_order (id,date,address,state,sum,goods_id,number,order_id,warehouse_keeper_id) values (#{id}, #{date},#{address}, #{state},#{sum}, #{goodsid},#{number}, #{orderid}, #{warehouseid})")
    boolean insert(PurchaseOrder purchaseOrder);



    @Select("select * from purchase_order where id = #{id}")
    PurchaseOrder select(int id);
}
